<?php

/**
 * Test: RobotLoader basic usage.
 *
 * @author     David Grudl
 * @category   Nette
 * @package    Nette\Loaders
 * @subpackage UnitTests
 */



require dirname(__FILE__) . '/../initialize.php';



// temporary directory
define('TEMP_DIR', dirname(__FILE__) . '/tmp');
T::purge(TEMP_DIR);
Environment::setVariable('tempDir', TEMP_DIR);


$loader = new RobotLoader;
$loader->addDirectory('../../Nette/');
$loader->addDirectory(dirname(__FILE__));
$loader->addDirectory(dirname(__FILE__)); // purposely doubled
$loader->register();

T::dump( class_exists('TestClass'), 'Class TestClass loaded?' );


__halt_compiler() ?>

------EXPECT------
Class %ns%TestClass loaded? bool(TRUE)
